<%@ page language="java" import="java.util.*,com.fescoservice.model.*" pageEncoding="UTF-8"%>
<%@page import="com.fescoservice.config.PropertiesConfig"%>

<%
	String langfilename = "/resources/message";
	Long countl =request.getAttribute("counts")==null?0:(Long) request.getAttribute("counts");
	String counts = Long.toString(countl);
	List customerlist =request.getAttribute("customerlist")==null?new ArrayList():(List<Company>) request.getAttribute("customerlist");
	String serchOptionSel =  request.getAttribute("SerchOptionSel")==null?"":(String)request.getAttribute("SerchOptionSel");
	String serchOptionValue =  request.getAttribute("SerchOptionValueSel")==null?"":(String)request.getAttribute("SerchOptionValueSel");
	int listSize=PropertiesConfig.getInstance().getInt("ListSize.Customer");
	int pageNumber =(Integer) request.getAttribute("pageNumber");
	int pageCount =(countl.intValue()/listSize)+((0==countl.intValue()%listSize)?0:1);
%>
<%@include file="../common/LocaleManager.jsp"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<title>Fesco Service</title>
		<link rel="stylesheet" href="<%=path%>/js/jquery/themes/redmond/jquery.ui.all.css">
		<script src="<%=path%>/js/jquery/jquery-1.5.1.js"></script>
		<script src="<%=path%>/js/jquery/external/jquery.bgiframe-2.1.2.js"></script>
		<script src="<%=path%>/js/jquery/ui/jquery.ui.core.js"></script>
		<script src="<%=path%>/js/jquery/ui/jquery.ui.widget.js"></script>
		<script src="<%=path%>/js/jquery/ui/jquery.ui.mouse.js"></script>
		<script src="<%=path%>/js/jquery/ui/jquery.ui.button.js"></script>
		<script src="<%=path%>/js/jquery/ui/jquery.ui.draggable.js"></script>
		<script src="<%=path%>/js/jquery/ui/jquery.ui.position.js"></script>
		<script src="<%=path%>/js/jquery/ui/jquery.ui.resizable.js"></script>
		<script src="<%=path%>/js/jquery/ui/jquery.ui.dialog.js"></script>
		<script src="<%=path%>/js/jquery/ui/jquery.effects.core.js"></script>
		<script src="<%=path%>/js/jquery/ui/jquery.effects.slide.js"></script>
		<script src="<%=path%>/js/jquery/jquery.pager.js"></script>
		<link rel="stylesheet" href="<%=path%>/css/admin.css">
		<link rel="stylesheet" href="<%=path%>/css/hrpage.css">
		<style type="text/css">
			#ValidDateTips{
				z-index: 100; 
				border: 1px solid #b9c9ef; 
				position: fixed;  
				width: 260px; 
				bottom: 2px; 
				display: block; 
				background: white; 
				height: 200px; 
				overflow: hidden; 
				right: 0px; 
			}
			.tipsHeader{
				border: #fff 1px solid; 
				border-bottom: medium none; 
				background-color: rgb(102,153,204); 
				width: 100%; 
				height: 25px; 
				font-size: 12px; 
				overflow: hidden; 
			}
			#tipsButton{
				text-align: center; 
				padding:5px 0 5px 0;
				width: 16px;  
				float: right; 
				color: white; 
				font-size: 12px; 
				overflow: hidden; 
				cursor: pointer; 
				font-weight: bold; 
			}
			.doyoo_status {
				
			}
			doyoo_status,doyoo_link{
				float:right;
				display:inline
			}
		</style>
		<script type="text/javascript">
			$(function() {
				function pageClick(pageclickednumber) { 
					document.forms.mainForm.action = '<%=path%>/action/Login.htm?cmd=hrViewList';
					document.forms.mainForm.page.value=pageclickednumber;
					document.forms.mainForm.submit();		
					//$("#pager").pager({ pagenumber: pageclickednumber, pagecount: 15, buttonClickCallback: PageClick 
				}
				$("#btnExcel").button().click(function() {
					document.forms.mainForm.action = '<%=path%>/action/Login.htm?cmd=hrViewList';
					document.forms.mainForm.submit();		
				});
				$("#btnSearch").button().click(function() {
					document.forms.mainForm.action = '<%=path%>/action/Login.htm?cmd=hrViewList';
					document.forms.mainForm.submit();		
				});
				$("#pager").pager({ pagenumber: <%=pageNumber%>, pagecount: <%=pageCount%>, buttonClickCallback: pageClick }); 
				$("#ValidDateTips").effect( 'slide', {'direction':'bottom'}, 500, null )
				$("#tipsButton").click(function() {
					$("#ValidDateTips").effect( 'slide', {'mode':'hide','direction':'bottom'}, 500, null )
				});
			});
			
			
			function viewContent(custId){
				document.forms.mainForm.action = '<%=path%>/action/Customer.htm?cmd=viewCustomer&Flag=hrLogin';	
				document.forms.mainForm.custId.value = custId;
				document.forms.mainForm.submit();
			}
			
			
			
			
		</script>
	</head>
	<body>
	
<div class="content">
<div class="back">
	<div class="menu">
		<ul>
			<li class="on"><a href="http://www.fescoservice.com" title="Search"><%=resource.getString("FS_T_APPLICATON_SEARCH")%></a></li>
			<li><a href="http://www.fescoservice.com" title="Visa, Invitation Letter, Employment License, Work Permit, Foreign Expert Certificate, Residence Permit and Company 

Registration Service..."><%=resource.getString("FS_T_CERT_SERVICE")%></a></li>
			<li><a href="http://www.fescoservice.com" title="Exit-Entry Services for Chinese citizens Including studying abroad, business trips, visit relatives or friends...">
			<%=resource.getString("FS_T_EXIT_SERVICE")%>

</a></li>
			<li><a href="http://www.fescoservice.com" title="China Driver License Application&Replacement, Motor Vehicle Registration&Rental One-Stop Service...">
			<%=resource.getString("FS_T_DRIVE_SERVICE")%></a></li>
			<li><a href="http://www.fescoservice.com" title="Report"><%=resource.getString("FS_T_REPORT_DOWNLOAD")%></a></li>
		</ul>
	</div>	
<!-- header begins -->
<div class="header">
	<div class="logo">
		<h1><a href="<%=path %>/images/main.jpg" target="_blank"><%=resource.getString("FS_T_FESCO_SERVICE")%></a></h1>
		<h2><a href="http://www.fescoservice.com/e/" id="metamorph"> <%=resource.getString("FS_T_FESCO_COMPANY_NAME")%> </a></h2>
	</div>
	<div class="toptext">
	<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;作为北京外企服务集团的成员企业，北京外企晨光劳务服务有限责任公司(Beijing FESCO Chenguang Labour Service Co.,Ltd.)成立于1994年，是为外籍人员、港澳台人员来华工作和生活提供全面的信息咨询及

代理服务、为中国公民提供因私出入境中介服务的专业涉外服务公司。经过多年发展，公司如今已取得国家和相关部门的多项涉外服务授权和合法资质，服务范围拓展到了多个方面。</p>
	<p class="more"><a href="http://www.fescoservice.com/c/ourcompany.php" target="_blank">more...</a></p>
	</div> 	
</div>
<!-- header ends -->
<!-- content begins -->
 <div class="main">
	<div class="right">
		
		
		<div class="wrapContent">		
			<form name="mainForm" method="post">
				<input type="hidden" name="page" value="" />
				<input type="hidden" name="custId" value="" />
			
			<div class="ui-widget categorylist">
				<div class="search">
					<%=resource.getString("FS_T_SEARCHBYTYPE")%>
					<select name="SerchOptionSel" id="SerchOptionSel" class=" ui-corner-all">
					
						<option value="2" <% if("2".equals(serchOptionSel)){%> selected="selected"	<% }%>><%=resource.getString("FS_T_CUST_NAME_EN")%></option>
						<option value="1" <% if("1".equals(serchOptionSel)){%> selected="selected"	<% }%>><%=resource.getString("FS_T_CUST_PASS_ID")%></option>
						
					</select>
					<input type="text" name="SerchOptionValueSel" class=" ui-corner-all"  value="<%=serchOptionValue %>" maxlength="80" />
					
					<div id="btnSearch" ><%=resource.getString("FS_T_SEARCH")%></div>
				</div>
				<h1>
					 <%=resource.getString("FS_T_TOTALCOUNT")%> :  <%=counts %> 
				</h1>
				<table class="ui-widget ui-widget-content">
					<thead>
						<tr class="ui-widget-header ">
							<th>
								<%=resource.getString("FS_T_CUST_NAME_EN")%>
							</th>
							<th>
								<%=resource.getString("FS_T_CUST_PASS_ID")%>							</th>
							
							<th>
								<%=resource.getString("FS_T_CUST_NAME_CN")%>
							</th>		
							<th>
								<%=resource.getString("FS_T_CUST_PASS_VALID_DATE")%>
							</th>	
							<th>
								<%=resource.getString("FS_T_CUST_COMPANY_NAME")%>
							</th>	
							<th>
								<%=resource.getString("FS_T_OPERATION_COL")%>
							</th>							
						</tr>
					</thead>
					<tbody>
					<% if(customerlist.size()>0) { 
						Customer customer = null;
						for(int i=0;i<customerlist.size();i++){
						customer = (Customer)customerlist.get(i);
					%>
					
						<tr class="operTR<%=i%2 %>" >
							<td>
								<%=customer.getCustFirstnameEn()+" "+customer.getCustLastnameEn() %>
							</td>
							<td>
								<%=customer.getPassId() %>
							</td>
							
							<td>
								<%=customer.getCustNameCn() %>
							</td>
							<td>
								<%=customer.getPassValidDate() %>
							</td>
							<td>
								<%=customer.getCompanyName() %>
							</td>
							<td>
								
								<a href="javascript:viewContent('<%=customer.getCustId()%>');" ><%=resource.getString("FS_T_VIEW")%><%=resource.getString("FS_T_CONTENT")%></a>
							</td>
						</tr>
					<%	}
					}else{ %>

						<tr>
							<td colspan="6">
								<%=resource.getString("FS_M_NORESULT")%>
							</td>
						</tr>
					<%} %>
					</tbody>
				</table>
				<div class="bottom">
					<div id="pager"></div>
				</div>
				<div class="buttonGroupRight">
			   		<div id="btnExcel" ><%=resource.getString("FS_T_EXCEL")%></div>
					
				</div>	
			</div>
			</form>
		</div>
		
		
		
	</div>
  	
<%@include file="../common/left.jsp"%>
</div>
<!--content ends -->

<%@include file="../common/footer.jsp"%>
</div>
</div>
<div id="ValidDateTips" >
	
	<div class="ui-widget-header ui-corner-all tipsHeader">
		<span id="tipsButton"><IMG border=0 src="<%=path %>/images/icon_close.gif"></span>
		<div style="line-height: 16px; padding-left: 8px; float: left; color: rgb(255,255,255); font-size: 14px; overflow: hidden; font-weight: bold; padding-top: 6px"><%=resource.getString("FS_T_INFO_TIPS")%></div>
		<div style="clear: both"></div>
	</div>
		<%=resource.getString("FS_M_INFO_TIPS1")%><font color="#2e6e9e">5</font><%=resource.getString("FS_M_INFO_TIPS2")%>
		<a style="color:#2e6e9e" href="#"><%=resource.getString("FS_M_INFO_TIPS3")%></a><%=resource.getString("FS_M_INFO_TIPS4")%>
</div>
 
<div style="right: 0; top: 200px; width: 169px; height: 331px; overflow: hidden; position: absolute; z-index: 7999;" id="iconDivMain1">
<div style='background: url("http://kf1.53kf.com/img/kflogo/close.gif") no-repeat; top: 3px; width: 11px; height: 11px; right: 5px; position: absolute; cursor: pointer;' onclick="kf_icons[1].hidden()"></div>
<div style='background: url("<%=path%>/images/callcenter.jpg") no-repeat; width: 169px; height: 331px; cursor: pointer;' onclick="setIsinvited();kf_icons[1].wopen('&amp;style=4&amp;language=zh-cn&amp;lytype=0&amp;charset=utf-8&amp;kflist=off&amp;kf=e51107e4-c0c5-102d-bbf6-0018716864bc&amp;zdkf_type=2&amp;referer=http%3A%2F%2Fwww.53kf.com%2Findex.php%3Fcity%3Dbeijing%26agent%3Dkangshang&amp;keyword=&amp;tfrom=1&amp;tpl=crystal_blue')"></div></div>

		<script type="text/javascript"	>	
		//import scripts below to pages which display in right frame, for ajust the scroll height
		parent.scroll(0,0);
		parent.setFrameHeight(document.body.scrollHeight+200);
		</script>
	</body>
</html>